package org.xxmi.interview;

import java.util.*;

public class Test4 {
    public static void main(String[] args) {

        List list = new ArrayList();
        list.add(1);
        list.add(true);
        list.get(0);

        Set set = new HashSet();
        set.add("a");
        set.add(1);
        set.add(true);

        Iterator iterator = set.iterator();
        while (iterator.hasNext()){
            Object next = iterator.next();
            System.out.println(next);
        }

        Map<String,Object> map = new HashMap<>();
        map.put("k1","v-k1");
        map.put("k2","v-k2");
        map.put("k3","v-k3");

        Set<String> strings = map.keySet();

        for(Map.Entry<String,Object> m:map.entrySet()){
            System.out.println(m.getKey()+" : "+m.getValue());
        }

        Vector vector = new Vector();
        vector.add("a");
        vector.add("a");
        vector.add("b");
        System.out.println(Arrays.toString(vector.toArray()));

        Set set2 = new HashSet();
        set2.addAll(vector);
        vector.clear();
        vector.addAll(set2);
        System.out.println(set2.toString());
        System.out.println(Arrays.toString(vector.toArray()));
        Test4 t4 = new Test4();
        System.out.println(t4.i);
    }
        int i;

    public void ab(int a,String b){

    }

    public void ab(String b,int a){

    }














}
